3d98a0c2add99d9ed88af4d654643710cf7c5097,src/test/java/com/aol/cyclops2/internal/stream/spliterators/standard/flatMap/iterable/IterableFlatMapTest.java,IterableFlatMapTest,flatMapAsyncRS3,#,208
Before Change
@Test
public void flatMapAsyncRS3(){
for(int k=0;k<100;k++) {
SeqSubscriber<Integer> sub = SeqSubscriber.subscriber();
Spouts.of(1, 2, 3).peek(System.out::println)
.flatMapI(i -> nextAsyncRS())
.subscribe(sub);
List<Integer> res = sub.stream().collect(Collectors.toList());
System.out.println(res);
assertThat(res.size(), equalTo(ListX.of(1, 2, 1, 2, 1, 2).size()));
assertThat(res, hasItems(1, 2));
After Change
List<Integer> res = Spouts.from(Spouts.of(1, 2, 3).peek(System.out::println)
.flatMapI(i -> nextAsyncRS())).collect(Collectors.toList());
System.out.println(res);
assertThat(res.size(), equalTo(ListX.of(1, 2, 1, 2, 1, 2).size()));
assertThat(res, hasItems(1, 2));